import os
import os.path
import shutil

print 'Going to clean all the cvs directory in the current & sub directorys'

def visit(arg, dirname, names):
    if dirname.endswith('CVS') == True:
        print 'remove CVS directory:%s' % (dirname, )
        shutil.rmtree(dirname)

print os.getcwd()
os.path.walk(".", visit, 0)    

print 'Done!'
